﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace STKMIS.Model
{
    /// <summary>
    /// 的实体类
    /// </summary>
    [Serializable]
    public class UserModel
    {
        // 常量
        public const string tableName = "Users";
        public const string primaryKeyName = "UserID";

        // 成员变量
        private int _userID;
        private string _loginCode;
        private string _loginPwd;
        private string _userName;
        private Boolean _isDeleted;

        /// <summary>
        /// 字段名结构
        /// <summary>
        public struct FieldName
        {
            public const string userID = "UserID";
            public const string loginCode = "LoginCode";
            public const string loginPwd = "LoginPwd";
            public const string userName = "UserName";
            public const string isDeleted = "IsDeleted";
        }

        /// <summary>
        /// 默认构造函数
        /// <summary>
        public UserModel() { }

        /// <summary>
        /// 带参构造函数
        /// <summary>
        ///<param name="userID"></param>
        ///<param name="loginCode"></param>
        ///<param name="loginPwd"></param>
        ///<param name="userName"></param>
        ///<param name="isDeleted"></param>
        public UserModel(int userID, string loginCode, string loginPwd, string userName, Boolean isDeleted)
        {
            this._userID = userID;
            this._loginCode = loginCode;
            this._loginPwd = loginPwd;
            this._userName = userName;
            this._isDeleted = isDeleted;
        }

        /// <summary>
        /// 
        /// <summary>
        public int UserID
        { 
            get { return _userID; }
            set { _userID = value; }
        }

        /// <summary>
        /// 
        /// <summary>
        public string LoginCode
        { 
            get { return _loginCode; }
            set { _loginCode = value; }
        }

        /// <summary>
        /// 
        /// <summary>
        public string LoginPwd
        { 
            get { return _loginPwd; }
            set { _loginPwd = value; }
        }

        /// <summary>
        /// 
        /// <summary>
        public string UserName
        { 
            get { return _userName; }
            set { _userName = value; }
        }

        /// <summary>
        /// 
        /// <summary>
        public Boolean IsDeleted
        { 
            get { return _isDeleted; }
            set { _isDeleted = value; }
        }
    }
}
